<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>CSV Editor</title>
</head>
<body>
    <h1>CSV Data</h1>
    <a href="{{ url_for('add_entry') }}">Add New Entry</a>
    <table border="1">
        <tr>
            <th>Name</th>
            <th>Age</th>
            <th>Email</th>
            <th>Actions</th>
        </tr>
        {% for row in data %}
        <tr>
            <td>{{ row['Name'] }}</td>
            <td>{{ row['Age'] }}</td>
            <td>{{ row['Email'] }}</td>
            <td><a href="{{ url_for('edit_entry', index=loop.index0) }}">Edit</a></td>
        </tr>
        {% endfor %}
    </table>
</body>
</html>